﻿<?xml version="1.0" encoding="utf-8"?>
<Window x:Class="SABnzbdNET.Views.AddTaskView"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="Add task" Height="320" Width="350" Icon="pack://application:,,,/Graphics/SABnzbd.ico" ShowInTaskbar="False" WindowState="Normal" ResizeMode="NoResize" WindowStartupLocation="CenterOwner">
    <Grid Margin="10">
		<GroupBox Name="grpProcessing" Header="Processing" VerticalAlignment="Top" HorizontalAlignment="Stretch" Margin="0,0,0,0" Height="135">
			<Grid>
                <ComboBox Height="25" Margin="10,10,10,0" Name="drpCategories" VerticalAlignment="Top" SelectedIndex="0" SelectedValuePath="Value" DisplayMemberPath="Key" SelectedValue="{Binding Path=Category, Mode=OneWayToSource}" ItemsSource="{Binding Path=Categories}" />
                <ComboBox Height="25" Margin="10,45,10,0" VerticalAlignment="Top" SelectedIndex="0" SelectedValuePath="Tag" SelectedValue="{Binding Path=Script, Mode=OneWayToSource}">
					<ComboBoxItem Tag="">Choose processing</ComboBoxItem>
                    <ComboBoxItem Tag="0">Download</ComboBoxItem>
                    <ComboBoxItem Tag="1">+Repair</ComboBoxItem>
					<ComboBoxItem Tag="2">+Unpack</ComboBoxItem>
					<ComboBoxItem Tag="3">+Delete</ComboBoxItem>
				</ComboBox>
                <ComboBox Height="25" Margin="10,80,10,0" VerticalAlignment="Top" SelectedIndex="0" SelectedValuePath="Tag" SelectedValue="{Binding Path=Priority, Mode=OneWayToSource}">
					<ComboBoxItem Tag="">Choose job priority</ComboBoxItem>
					<ComboBoxItem Tag="-1">Low</ComboBoxItem>
					<ComboBoxItem Tag="0">Normal</ComboBoxItem>
					<ComboBoxItem Tag="1">High</ComboBoxItem>
				</ComboBox>
			</Grid>
		</GroupBox>
		<GroupBox Name="grpUpload" Header="Upload nzb file" VerticalAlignment="Top" HorizontalAlignment="Stretch" Margin="0,135,0,0" Height="50">
			<Grid>
                <TextBox Height="25" Margin="0,0,95,0" VerticalAlignment="Top" HorizontalAlignment="Stretch" Text="{Binding Path=FileName}" ToolTip="{Binding Path=FileName}" />
                <Button Height="23" Content="Browse" VerticalAlignment="Top" HorizontalAlignment="Right" Margin="0,0,0,0" Width="85" Command="{Binding Path=BrowseCommand}" />
			</Grid>
		</GroupBox>
		<GroupBox Name="grpNewzbin" Header="Add by Newzbin ID" VerticalAlignment="Top" HorizontalAlignment="Stretch" Margin="0,185,0,0" Height="50">
			<Grid>
                <TextBox Height="25" Margin="0,0,0,0" Name="txtNewzbinId" VerticalAlignment="Top" HorizontalAlignment="Stretch" Text="{Binding Path=NewzbinId}" />
			</Grid>
		</GroupBox>
        <Button Height="25" Margin="0,0,95,0" VerticalAlignment="Bottom" HorizontalAlignment="Right" Width="85" Command="{Binding Path=UploadCommand}">Ok</Button>
        <Button Height="25" Margin="0,0,0,0" VerticalAlignment="Bottom" HorizontalAlignment="Right" Width="85" Command="{Binding Path=CloseWindowCommand}">Cancel</Button>
	</Grid>
</Window>